package org.dromara.system.domain.bo;

import org.dromara.system.domain.EmailAccount;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

/**
 * 邮箱账号业务对象 email_account
 *
 * @author Gavino
 * @date 2024-11-18
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = EmailAccount.class, reverseConvertGenerate = false)
public class EmailAccountBo extends BaseEntity {

    /**
     * 主键ID
     */
    @NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
    private Long id;

    /**
     * 邮箱账号
     */
    @NotBlank(message = "邮箱账号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String account;

    /**
     * 邮箱密码
     */
    @NotBlank(message = "邮箱密码不能为空", groups = { AddGroup.class, EditGroup.class })
    private String password;

    /**
     * 服务器协议
     */
    @NotBlank(message = "服务器协议不能为空", groups = { AddGroup.class, EditGroup.class })
    private String agreement;

    /**
     * 服务器地址
     */
    @NotBlank(message = "服务器地址不能为空", groups = { AddGroup.class, EditGroup.class })
    private String server;

    /**
     * 端口
     */
    @NotBlank(message = "端口不能为空", groups = { AddGroup.class, EditGroup.class })
    private String port;

    /**
     * 账号状态
     */
    private Integer status;

    /**
     * 账号类型 0：默认 1: 订单支付提醒账号
     */
    private Integer type;

    /**
     * 是否启用ssl
     */
    @NotNull(message = "是否启用ssl不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer enableSsl;

    /**
     * 备注
     */
    private String remark;

    /**
     * 是否删除
     */
    private Integer isDelete;

    /**
     * 创建人ID
     */
    private Long createId;

    /**
     * 创建者
     */
    private String createName;

    /**
     * 更新人ID
     */
    private Long updateId;

    /**
     * 更新者
     */
    private String updateName;


}
